<template>

  <el-dialog v-model="show"
             title=""
             @open="copyData"
             :close-on-click-modal="true"
             :width="'60%'">
    <div style="padding: 12px;">
      <el-form ref="formRef" style="max-width: 600px" label-width="auto" class="demo-ruleForm">

      </el-form>
    </div>
    <template #footer>
      <span class="dialog-footer">
        <el-button @click="()=>{show=false}" type="danger">取消</el-button>
        <el-button @click="" style="margin: 0 16px;" type="primary">确认修改</el-button>
      </span>
    </template>
  </el-dialog>

</template>

<script setup>
import {ref} from "vue";

const show = defineModel();

const props = defineProps({
  info: {
    type: Object,
    required: true
  },
  after: {
    type: Function,
    required: true
  }
});

const infoInstance = ref({})

async function copyData(){
  infoInstance.value = JSON.parse(JSON.stringify(props.info));
}

</script>

<style scoped>

</style>